package com.demo.pattern.decorate.homework;

/**
 * @author sourire
 * @version 1.0
 * @date 2020/8/27 14:52
 */
public class MD5 extends CondimentDecorator {
    Encode encode;

    MD5(){
        str = "MD5";
    }
    @Override
    public String getStr() {
        return encode.getStr()+"，经过"+str+"加密";
    }

    @Override
    public String encode() {
        return encode.encode()+this.str;
    }
}
